#include "fromcomponent.h"

FromComponent::FromComponent(const string & name, const string & rename)
{
    this->name = name;
    this->rename = rename;
}

FromComponent::~FromComponent()
{
    name = "";
    rename = "";
}

FromComponent::FromComponent(const FromComponent& other)
{
    name = other.name;
    rename = other.rename;
}

string FromComponent::getRename()
{
    return rename;
}

string FromComponent::getName()
{
    return name;
}

void FromComponent::setRename(const string & rename)
{
    this->rename = rename;
}

void FromComponent::setName(const string & name)
{
    this->name = name;
}

string FromComponent::toString()
{
    return "<" + name + " as " + rename + ">";
}

FromComponent * FromComponent::clone()
{
    return new FromComponent(*this);
}
